package com.example.philosophy.dilp;

/**
 * 测试依赖倒转原则。。。。。。。
 */
public class TestCar {
    public static void main(String[] args) {

        //创建火车
        FireCar fireCar=new FireCar();

        //创建司机
        Driver driver=new Driver(fireCar);
        driver.play();
        //创建飞船
        FlyBoat flyBoat=new FlyBoat();
        Driver driver1=new Driver(flyBoat);
        driver1.play();
    }
}
